<#escape x as x?html>
<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>打印测试界面</title>
    <link rel="stylesheet" type="text/css" href="${rc.contextPath}/resources/css/easyui.css">
    <link rel="stylesheet" type="text/css" href="${rc.contextPath}/resources/css/icon.css">
    <script type="text/javascript" src="${rc.contextPath}/resources/js/jquery-1.8.0.min.js"></script>
    <script type="text/javascript" src="${rc.contextPath}/resources/js/jquery.easyui.min.js"></script>
    <script type="text/javascript" src="${rc.contextPath}/resources/js/easyui-lang-zh_CN.js"></script>
    <script type="text/javascript" src="${rc.contextPath}/resources/js/jquery.jqprint.js"></script>
    <script type="text/javascript">
        $(function() {
            $('#dg').datagrid(
                {
                    title:'test',
                    fitColumns: true,
                    fit: true,
                    toolbar: [
                        {
                            text: '打印',
                            iconCls: 'icon-add',
                            handler: function () {
                                $('#dg').jqprint();
                            }
                        }
                    ],
                    columns:[
                        [
                            {field: 'id', title: 'ID', align: 'center', width: 50},
                            {field: 'name', title: '姓名', align: 'center', width: 50},
                            {field: 'age', title: '年龄', align: 'center', width: 50}
                        ]
                    ],
                    data: [
                        {'id': 1,'name':'张三','age':34},
                        {'id': 2,'name':'李四','age':23}
                    ]
                }
            );
        });
    </script>
</head>
<body>

<div id="dg" style="width:800px;height: 600px;"><table class="easyui-datagrid"></table></div>


</body>

</html>
</#escape>